<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<meta charset="utf-8">
<head th:include="include :: header"></head>
<link th:href="@{/ajax/libs/iCheck/custom.css}" rel="stylesheet"/>
<link href="/ajax/libs/jquery-ztree/3.5/css/metro/zTreeStyle.css" th:href="@{/ajax/libs/jquery-ztree/3.5/css/metro/zTreeStyle.css}" rel="stylesheet"/>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
    <form class="form-horizontal" id="form-do-add">
        <div class="form-group">
            <label class="col-sm-3 control-label">金融融资:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="financeId"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">银行:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="bankId"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">登录名:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="ownName"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">姓名:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="realName"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">电话:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="phone"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">编码:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="idNum"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">状态:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="status"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="remark"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="money"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="rate"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="repayment"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="updateTime"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="combinationName1"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="combinationPhone1"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="combinationIdnum1"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="combinationName2"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="combinationPhone2"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="combinationIdnum2"></div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">:</label>
            <div class="col-sm-8"><input class="form-control" type="text" name="fileInfo"></div>
        </div>
        <div class="form-group">
            <div class="form-control-static col-sm-offset-9">
                <button type="button" class="btn btn-primary" onclick="addDoSave()">提交</button>
                <button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>
            </div>
        </div>
    </form>
</div>
<div th:include="include::footer"></div>
<script type="text/javascript">
    layui.use('laydate', function () {
        var laydate = layui.laydate;//时间选择器
        laydate.render({
            elem: '#inDate', type: 'date'
        });
    });

    var prefix = "/tbFinance"
    function addDoSave() {
        $.ajax({
            cache: true,
            type: "POST",
            url: prefix+"/addSave",
            data: {
                financeId: $("input[name='financeId']").val(),
                bankId: $("input[name='bankId']").val(),
                ownName: $("input[name='ownName']").val(),
                realName: $("input[name='realName']").val(),
                phone: $("input[name='phone']").val(),
                idNum: $("input[name='idNum']").val(),
                status: $("input[name='status']").val(),
                remark: $("input[name='remark']").val(),
                money: $("input[name='money']").val(),
                rate: $("input[name='rate']").val(),
                repayment: $("input[name='repayment']").val(),
                createTime: $("input[name='createTime']").val(),
                updateTime: $("input[name='updateTime']").val(),
                combinationName1: $("input[name='combinationName1']").val(),
                combinationPhone1: $("input[name='combinationPhone1']").val(),
                combinationIdnum1: $("input[name='combinationIdnum1']").val(),
                combinationName2: $("input[name='combinationName2']").val(),
                combinationPhone2: $("input[name='combinationPhone2']").val(),
                combinationIdnum2: $("input[name='combinationIdnum2']").val(),
                fileInfo: $("input[name='fileInfo']").val(),
            },
            async: false,
            traditional: true,
            error: function (request) {
                $.modal.alertError("系统错误");
            },
            success: function (data) {
                $.operate.saveSuccess(data);
            }
        });
    }
</script>
</body>
</html>